
Global Population Growth and Decline
Table of Contents
- Chosen Visualisation Example
- Critical Assessment of the Original Visualisation
- Data Used & Data Preparation Process
- Steps Taken to improve the plot
- Final Visualisation Demo
Chosen Data Visualisation Example (Part 1)
Chosen Data Visualisation Example (Part 2)

General
- Three variables: country population and fertility rate
- Depiction of Population through bubble size with a relevant Legend

General
- Colour Coding to distinguish between countries with regards to Fertility Rate
- Interactive features such as hover text to see Fertility rate

Strengths
- Colour Contrast
- Bubble Sizes
- Clear Y-Axis
Weaknesses
- Entire graph not visible without scrolling
- Population size precision through bubbles
- Difficult to search for specific countries data
- Clutter of bubbles
Data Used
- Loaded the U.N. World Population Prospects 2022 dataset.
- Decided on the U.N. dataset over the World Bank dataset due to fewer missing fertility values.
- Used R’s built-in “world” dataset for initial country outlines and mapping context.
Data Prepation Process (Fertility and Population Data)
- Utilized Columns Population, Fertility Rate for year 2022, and Country Name.
- Removed NA Columns
- Converted Fertility Rate to Numeric
Cleaning and processing of data, output top 6 rows
X Country Fertility Population Test CountryCode
1 1 Niger 6.820 24785.587 NER NER
2 2 Somalia 6.312 16801.170 SOM SOM
3 3 Chad 6.255 16910.218 TCD TCD
4 4 Democratic Republic of the Congo 6.156 94374.379 COD COD
5 5 Central African Republic 5.978 5414.014 CAF CAF
6 6 Mali 5.956 21561.299 MLI MLI
Data Preparation Process (Geographic Data)
- Joined demographic data with R’s world map by country region.
- Imported and processed GeoJSON files for detailed country and land borders.
- Simplified geometries for improved performance and validated with spatial data standards.
- Standardized data to “MULTIPOLYGON” format for mapping compatibility.
- Prepared base map layer and custom polygon objects for visualization.
- Combined spatial and demographic data for mapping fertility and population metrics.
- Curated data columns for final visual display.
Improvements to Original Plot
- Changed to a Map Visualisation
- Utilised ColorBrewer’s palette to colour code different Fertility Rate in a range from 1-7
- Implemented Sequential Binned Colours for accessibility
- In built ggplotly modebar to Zoom in the map to look for smaller countries
- Hover-effect over countries to show fertility rate and population data
Initial Plot
Add ColourBrewer’s colour gradient to the map
Plotting on GGPlotly
Additions to the Plot
- Line Chart to show correlation between Population Size and Fertility Rate
- Added a data table that allows you to search for a country & each column can filter by min/max
- Scrollable scale on the LHS to toggle replacement fertility ranges
- Button-toggle to show countries below replacement fertility
Usage of Shiny
- Shiny enables the creation of interactive web applications.
- Reduce the load on the client-side and speed up the application’s performance.
- Allow interactions and animation such as the slider and button function to display on our world map:
- Dynamic Filtering:
- Conditional Display: